<?php if(!defined('HDPHP_PATH'))exit;C('SHOW_NOTICE',FALSE);?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">

	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
		<title>分类管理</title>
		<script>
			var CONTROLLER = 'http://127.0.0.1/cms/cms/index.php/Admin/Category';
		</script>
		<link type="text/css" rel="stylesheet" href="http://127.0.0.1/cms/cms/Static/hdjs/hdjs.css"/>
		<script type="text/javascript" src="http://127.0.0.1/cms/cms/Static/js/jq.js"></script>
		<script type="text/javascript" src="http://127.0.0.1/cms/cms/Application/Admin/View/Category/js/ajax_check.js"></script>

	</head>

	<body>
		<div class="wrap">

			<div class="hd-title-header">
				编辑分类
			</div>

			<form action="http://127.0.0.1/cms/cms/index.php/Admin/Category/editcate" method="post" class="form-inline hd-form">
				<table class="hd-table hd-table-list">
					<tr>
						<th class="w100">修改分类</th>
						<td class="w100">
							<input type="text" name="cname" class="w200" value="<?php echo $cate['cname'];?>" />
							<input type="hidden" name="cid" value="<?php echo $cate['cid'];?>" />
						</td>
						<td>分类名称长度 1 到 20 位</td>
					</tr>
					<tr>

						<th class="w100">修改为</th>
						<td>
							<select name="pid">
								<option value="0">顶级分类</option>
								<?php foreach ($data as $key=>$val){?>
									<option value="<?php echo $val['cid'];?>"><?php echo $val['_name'];?></option>
								<?php }?>
							</select>
						</td>
						<td></td>
					</tr>
					<tr>
						<th class="w100">分类标题</th>
						<td>
							<input type="text" name="ctitle" class="w200" value="<?php echo $cate['ctitle'];?>" />
						</td>
						<td> 分类标题长度 1 到 60 位 </td>
					</tr>
					<tr>
						<th class="w100">分类关键字</th>
						<td>
							<textarea name="ckeywords" id="" class="form-control" rows="5"><?php echo $cate['ckeywords'];?></textarea>
						</td>
						<td>分类关键字长度 1 到 255位</td>
					</tr>
					<tr>
						<th class="w100">分类描述</th>
						<td>
							<textarea name="cdes" id="" class="form-control" rows="5"><?php echo $cate['cdes'];?></textarea>
						</td>
						<td>分类描述长度 1 到 255位 </td>
					</tr>
					<tr>
						<th class="w100">分类排序</th>
						<td>
							<input type="text" name="csort" class="w200" value="<?php echo $cate['csort'];?>" />
						</td>
						<td>请填写1到65535的排序数字 </td>
					</tr>
					<tr>
						<th class="w100">静态目录</th>
						<td>
							<input type="text" name="htmldir" class="w200" value="<?php echo $cate['htmldir'];?>" />
						</td>
						<td>请填写1~20位只包含字母数字下划线,分类静态目录 例如：php</td>
					</tr>
					<tr>
						<th class="w100">列表页是否静态</th>
						<td>
							是：
							<input type="radio" name="is_listhtml" id="" value="1"     <?php if($cate['is_listhtml']==1){ ?>checked="checked"<?php } ?> /> &nbsp; 否:
							<input type="radio" name="is_listhtml" id="" value="0"     <?php if($cate['is_listhtml']==0){ ?>checked="checked"<?php } ?> />
						</td>
						<td></td>
					</tr>
					<tr>
						<th class="w100">内容页是否静态</th>
						<td>
							是：
							<input type="radio" name="is_archtml" id="" value="1"     <?php if($cate['is_archtml']==1){ ?>checked="checked"<?php } ?> /> &nbsp; 否:
							<input type="radio" name="is_archtml" id="" value="0"     <?php if($cate['is_archtml']==0){ ?>checked="checked"<?php } ?> />
						</td>
						<td></td>
					</tr>
					<tr>
						<th class="w100">是否显示</th>
						<td>
							是：
							<input type="radio" name="is_show" id="" value="1"     <?php if($cate['is_show']==1){ ?>checked="checked"<?php } ?> /> &nbsp; 否:
							<input type="radio" name="is_show" id="" value="0"     <?php if($cate['is_show']==0){ ?>checked="checked"<?php } ?> />
						</td>
						<td></td>
					</tr>
				</table>
				<div class="position-bottom">
					<input type="submit" class="hd-btn hd-btn-primary hd-btn-lg" value="修改" />
					<a href="<?php echo U('index');?>" class="hd-btn hd-btn-danger hd-btn-lg">返回</a>
				</div>
			</form>
		</div>
	</body>

</html>